/* -*-  Mode: C++; c-file-style: "gnu"; indent-tabs-mode:nil; -*- */
/*
 * Copyright (c) 2007 INESC Porto
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 as
 * published by the Free Software Foundation;
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
 *
 * Author: Gustavo J. A. M. Carneiro  <gjc@inescporto.pt>
 */

#ifndef TEXCP_HEADER_H
#define TEXCP_HEADER_H

#include <stdint.h>
#include <vector>
#include "ns3/header.h"
#include "ns3/ipv4-address.h"
#include "ns3/nstime.h"


namespace ns3 {
namespace texcp{


class TexcpHeader : public Header
{
public:
  TexcpHeader ();
  virtual ~TexcpHeader ();

  /*void SetPacketLength (uint16_t length)
  {
    m_packetLength = length;
  }
  uint16_t GetPacketLength () const
  {
    return m_packetLength;
  }

  void SetPacketSequenceNumber (uint16_t seqnum)
  {
    m_packetSequenceNumber = seqnum;
  }
  uint16_t GetPacketSequenceNumber () const
  {
    return m_packetSequenceNumber;
  }*/
  void SetPathUtilization (uint16_t length)
  {
    m_path_utilization = length;
  }
  uint16_t GetPathUtilization () const
  {
    return m_path_utilization;
  }
  void SetPosFeedBack (uint16_t length)
  {
    m_positive_feedback = length;
  }
  uint16_t GetPosFeedBack () const
  {
    return m_positive_feedback;
  }
  void SetNegFeedBack (uint16_t length)
  {
    m_negative_feedback = length;
  }
  uint16_t GetNegFeedBack () const
  {
    return m_negative_feedback;
  }
  void SetWeight (uint16_t length)
  {
    m_weight = length;
  }
  uint16_t GetWeight () const
  {
    return m_weight;
  }
private:
  /*uint16_t m_packetLength;
  uint16_t m_packetSequenceNumber;*/
  uint16_t m_path_utilization;
  uint16_t m_positive_feedback;
  uint16_t m_negative_feedback;
  uint16_t m_weight;

public:  
  static TypeId GetTypeId (void);
  virtual TypeId GetInstanceTypeId (void) const;
  virtual void Print (std::ostream &os) const;
  virtual uint32_t GetSerializedSize (void) const;
  virtual void Serialize (Buffer::Iterator start) const;
  virtual uint32_t Deserialize (Buffer::Iterator start);
};


}} // namespace texcp, ns3

#endif /* OLSR_HEADER_H */

